from conftest import login_token4
import pytest,requests

class Test_science:
    # 创建群聊
    def test_science_01(self,login_token4):
        userId,sessionId=login_token4
        url="https://10.59.9.18/techApi/group/verify/v1/createGroup"
        headers={
            'userId':str(userId),
            'sessionId':str(sessionId)
        }
        data={
            'name':'热热热热热热热热热热热仍然然然然然然然然然然',
            'description':'欢迎大家'
        }
        r=requests.post(url=url,headers=headers,params=data,verify=False)
        r_json=r.json()
        print(r_json)
        # 解散群聊
    def test_science_02(self,login_token4):
        userId,sessionId=login_token4
        url="https://10.59.9.18/techApi/group/verify/v1/disbandGroup"
        headers={
            'userId':str(userId),
            'sessionId':str(sessionId)
        }
        data={
            'groupId':1
        }
        r=requests.delete(url=url,headers=headers,params=data,verify=False)
        r_json=r.json()
        print(r_json)